package Pstatic;

public class Student {
    private String name; // 姓名
    private int age; // 年龄
    private int[] marks; // 成绩

    // 静态变量
    //简单理解为一个班级的人数
    //静态变量属于类，不属于对象
    private static int count; // 学生人数


    public Student() {
    }

    public Student(String name, int age, int[] marks) {
        this.name = name;
        this.age = age;
        this.marks = marks;
    }

    /**
     * 获取
     * @return count
     */
    public static int getCount(Student s) {
        s.name="张三";
        return count;
    }

    /**
     * 设置
     * @param count
     */
    public static void setCount(int count) {
        Student.count = count;
    }

    /**
     * 获取
     * @return name
     */
    public String getName() {
        return name;
    }

    /**
     * 设置
     * @param name
     */
    public void setName(String name) {
        this.name = name;
    }

    /**
     * 获取
     * @return age
     */
    public int getAge() {
        return age;
    }

    /**
     * 设置
     * @param age
     */
    public void setAge(int age) {
        this.age = age;
    }

    /**
     * 获取
     * @return marks
     */
    public int[] getMarks() {
        return marks;
    }

    /**
     * 设置
     * @param marks
     */
    public void setMarks(int[] marks) {
        this.marks = marks;
    }

    public void show() {
        System.out.println("姓名：" + name + "，年龄：" + age );
    }
}
